from pyecharts.charts import Bar
from pyecharts.options import LabelOpts

bar = Bar()

bar.add_xaxis(['中国', '美国', '日本'])
bar.add_yaxis('GDP', [888, 777, 666], label_opts=LabelOpts(position='right'))
# 轴反转
bar.reversal_axis()

bar.render('1 基础柱状图.html')
